package com.itheima.chrendConstructor;

public class Test2 {
    public static void main(String[] args) {
        Teacher t =  new Teacher("王五", 18, "java 前端 大数据");
        System.out.println(t.getName());
        System.out.println(t.getAge());
        System.out.println(t.getSikll());

    }
}

class Teacher extends People{
    private String sikll;

    public Teacher(String name, int age, String sikll) {
        super(name, age);
        this.sikll = sikll;
    }

    public String getSikll() {
        return sikll;
    }

    public void setSikll(String sikll) {
        this.sikll = sikll;
    }
}



class People{
    private String name;
    private int age;

    public People(String name, int age) {
        this.name = name;
        this.age = age;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }
}